Skip to content

Comments

Add Support for Char Literals#153

Open
rcosta358 wants to merge 3 commits intomainfrom
chars
Open

Add Support for Char Literals#153
rcosta358 wants to merge 3 commits intomainfrom
chars

Conversation

@rcosta358
Copy link
Collaborator

This PR adds support for char literals, preventing the exception Literal of type char not implemented when chars are used in the Java source code. In the SMT solver, char literals are translated to their corresponding integer representation.

@rcosta358 rcosta358 self-assigned this Feb 16, 2026
@rcosta358 rcosta358 added the enhancement New feature or request label Feb 16, 2026
Copy link
Collaborator

@CatarinaGamboa CatarinaGamboa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! We should be careful in the future if we want to have more operations with chars inside the refinements, since they can be misleading since we are using only their int values.
If possible add a test with a char being used as an int like

// function
void write(int x){...}
// client
write('c');

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants